<template style=" text-align: center;">
	<el-dialog v-model="isShowDialog" draggable="" style="background-color:#39ac9d; width: 1200px;" @close="cancel"> 
			<div style="background-color:#39ac9d; color: #FFF; text-align: center;min-height: 40px;margin-top: 20px;">
				<!--<el-icon size="16" style="margin-right: 3px; display: inline; vertical-align: middle"> <ele-Edit /> </el-icon>-->
				<span>仿真登录</span>
			</div>
			<div style="text-align: center;">
				<div style="text-align:center;min-height:50px">
					<el-input ref="accountRef" text placeholder="请输入账号" v-model="a" style="text-align: center;width:200px" clearable
						autocomplete="off">
						<template #prefix>
							<el-icon>
								<ele-User />
							</el-icon>
						</template>
					</el-input>
				</div>
				<div>
					<p />
					<p />
					<p />
					<p />
					<p />
					<p />
				</div>
				<div style="text-align:center;min-height:50px">
					<el-input ref="passwordRef" type="password" v-model="b" placeholder="请输入密码" style="width:200px"
						autocomplete="off">
						<template #prefix>
							<el-icon>
								<ele-Unlock />
							</el-icon>
						</template>
						<template #suffix>
							<i class="iconfont el-input__icon login-content-password icon-xianshimima">
							</i>
						</template>

					</el-input>
				</div>
				<div>
					<p />
					<p />
					<p />
					<p />
					<p />
					<p />
				</div> 
					<el-button type="primary" style="width: 100px;border: 2px solid #FFF;" @click="closeDialog" v-waves>
						<span>{{ $t('message.account.accountBtnText') }}</span>
					</el-button>
				 
			</div> 
	</el-dialog>
</template>
<style scoped>
:deep(.el-select),
:deep(.el-input-number) {
	width: 100%;
}
</style>
<script lang="ts" setup="PDetail">

import { ref, onMounted, defineAsyncComponent } from "vue";
import { ElMessage } from "element-plus";
import type { FormRules } from "element-plus";
import { addProjectResult, updateProjectResult } from "/@/api/main/projectResult";
const Account = defineAsyncComponent(() => import('/@/views/login/component/account.vue'));
import { useI18n } from 'vue-i18n';
const { t, locale } = useI18n();
const a=ref();
const b=ref();
//父级传递来的参数
var props = defineProps({
	title: {
		type: String,
		default: "",
	},
});
const openvm = () => {

}
//父级传递来的函数，用于回调
const emit = defineEmits(["updateData"]);
const ruleFormRef = ref();
const isShowDialog = ref(false);
const ruleForm = ref<any>({});
//自行添加其他规则

// 打开弹窗
const openDialog = (row: any) => {
	// ruleForm.value = JSON.parse(JSON.stringify(row));
	isShowDialog.value = true;
};

// 关闭弹窗
const closeDialog = () => {
	emit("updateData");
	isShowDialog.value = false;
};

// 取消
const cancel = () => {
	isShowDialog.value = false;
};

// 提交
const submit = async () => {
	let values = ruleForm.value;
	if (ruleForm.value.id == undefined || ruleForm.value.id == null || ruleForm.value.id == "" || ruleForm.value.id == 0) {
		await addProjectResult(values);
	} else {
		await updateProjectResult(values);
	}
	closeDialog();


};







// 页面加载时
onMounted(async () => {
});

//将属性或者函数暴露给父组件
defineExpose({ openDialog });
</script>
